//
//  IWPopMenu.h
//
//
//  Created by apple on .
//  Copyright (c) 2014年 itcast. All rights reserved.
//

#import <UIKit/UIKit.h>

@class TTPopMenuView;

@protocol IWPopMenuViewDelegate <NSObject>

- (void)popMenuViewDidClick:(TTPopMenuView *)popMenuView;

@end

@interface TTPopMenuView : UIView
/**
 *  快速创建方法
 *
 *  @param contentView 需要显示的内容
 *
 *  @return 菜单
 */
+ (instancetype)popMenuContentView:(UIView *)contentView;
- (instancetype)initWithContentView:(UIView *)contentView;

/**
 *  显示菜单
 *
 *  @param rect 菜单的frame(黑色图片的frame)
 */
- (void)show:(CGRect)rect;
/**
 *  隐藏菜单
 */
- (void)dismiss;

@property (nonatomic, weak) id<IWPopMenuViewDelegate> delegate;

- (void)setContainerViewBg:(UIImage *)image;

@end
